<div class="panel panel-primary">
    <div class="panel-heading">
        <h3 class="panel-title">Registration</h3>
    </div>
<div class="panel-body">
    
    <form class="form-horizontal" action="signup" method="post">

            <fieldset>

                <c:if test="${!empty errors}">
                    <div class="row">
                    <div class="form-group">
                        <div class="alert alert-danger alert-dismissable col-sm-10 col-sm-offset-1"><strong>Registration failed.</strong>  Form incomplete.</div>
                    </div>
                    </div>
                </c:if>
                        
                <div class="form-group ${empty errors['fname'] ? '': 'has-error'}">
                    <label class="control-label col-sm-2" for="fname">First Name</label>
                    <div class="col-sm-7">
                        <input type="text" id="fname" name="fname" class="form-control" maxlength="45" size="60" placeholder="Type your first name" value="${fname}"/>
                        <c:if test="${!empty errors['fname']}">
                            <span class="help-block">${empty errors['fname'] ? 'Success': errors['fname']}</span>
                        </c:if>
                    </div>
                </div>

                <div class="form-group ${empty errors['lname'] ? '': 'has-error'}">
                    <label class="control-label col-sm-2" for="lname">Last Name</label>
                    <div class="col-sm-7">
                        <input type="text" id="lname" name="lname" class="form-control" maxlength="45" size="60" placeholder="Type your first name" value="${lname}"/>
                        <c:if test="${!empty errors['lname']}">
                            <span class="help-block">${empty errors['lname'] ? 'Success': errors['lname']}</span>
                        </c:if>
                    </div>
                </div>

                <div class="form-group ${empty errors['email'] ? '': 'has-error'}">
                    <label class="control-label col-sm-2" for="email">Email</label>
                    <div class="col-sm-7">
                        <input type="text" id="email" name="email" class="form-control" maxlength="45" size="60" placeholder="Type your email" value="${email}"/>
                        <c:if test="${!empty errors['email']}">
                            <span class="help-block">${empty errors['email'] ? 'Success': errors['email']}</span>
                        </c:if>
                    </div>
                </div>

                <div class="form-group ${empty errors['password'] ? '': 'has-error'}">
                    <label class="control-label col-sm-2" for="password">Password</label>
                    <div class="col-sm-7">
                        <input type="password" id="password" name="password" class="form-control" maxlength="20" size="60" placeholder="Type your password"/>
                        <c:if test="${!empty errors['password']}">
                            <span class="help-block">${empty errors['password'] ? 'Success': errors['password']}</span>
                        </c:if>
                    </div>
                </div>

                <div class="form-group ${empty errors['password'] ? '': 'has-error'}">
                    <label class="control-label col-sm-2" for="passwordc">Confirm</label>
                    <div class="col-sm-7">
                        <input type="password" id="passwordc" name="passwordc" class="form-control" maxlength="20" size="60" placeholder="Confirm your password"/>
                        <c:if test="${!empty errors['password']}">
                            <span class="help-block">${empty errors['password'] ? 'Success': errors['password']}</span>
                        </c:if>
                    </div>
                </div>

                <div class="form-group ${empty errors['phone'] ? '': 'has-error'}">
                    <label class="control-label col-sm-2" for="phone">Phone</label>
                    <div class="col-sm-7">
                        <input type="text" id="phone" name="phone" class="form-control" maxlength="45" size="60" placeholder="Type your phone number" value="${phone}"/>
                        <c:if test="${!empty errors['phone']}">
                            <span class="help-block">${empty errors['phone'] ? 'Success': errors['phone']}</span>
                        </c:if>
                    </div>
                </div>

                <div class="form-group ${empty errors['address'] ? '': 'has-error'}">
                    <label class="control-label col-sm-2" for="address">Address</label>
                    <div class="col-sm-7">
                        <textarea id="adress" name="address" class="form-control" placeholder="Type your address" size="60">${address}</textarea>
                        <c:if test="${!empty errors['address']}">
                            <span class="help-block">${empty errors['address'] ? 'Success': errors['address']}</span>
                        </c:if>
                    </div>
                </div>

                <c:if test="${!empty form.resultat}">
                    <div class="alert alert-${empty errors ? 'success' : 'danger'} alert-dismissable">
                        <button type="button" class="close" data-dismiss="alert" aria-hidden="true">&times;</button>
                        <strong>${form.resultat}</strong>
                    </div>
                </c:if>

                <div class="form-group">
                    <div class="col-sm-offset-3 col-sm-2">
                        <input type="submit" class="btn btn-primary" value="Register">
                    </div>
                    <div class="col-sm-2 ">
                        <input type="reset" class="btn btn-default" value="Reset">
                    </div>
                </div>       

            </fieldset>

        </form>
    </div>
</div>